#!/usr/bin/env python
# -*- coding: utf-8 -*-
from flask.ext.wtf import Form
from wtforms import StringField, TextField, BooleanField, SelectField, \
    SubmitField, IntegerField, PasswordField
from wtforms.validators import Required, Length, Email, Regexp,IPAddress, URL, EqualTo
from ..models import Tomcat, Project,Nginx, Host, Vhost

class HostForm(Form):
    hostname = StringField('Hostname', validators=[Required()])
    OS = StringField('Option System version:', validators=[Required()])
    IP = StringField('interna IP', validators=[Required(),IPAddress()])
    sshport = IntegerField('SSH Port', validators=[Required()], default=22)
    loginUser = StringField('SSH Login User', validators=[Required()], default='root')
    loginPass = PasswordField('SSH Login Password',validators=[Required(), EqualTo('loginPass_verfiy', message='Passwords must match')])
    loginPass_verfiy = PasswordField('Password Verfiy', validators=[Required()])
    submit = SubmitField('Submit')


class EditHostForm(Form):
    pass


